Hide rooms on overview page while preview image fails to load #207
+60
−2
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This fixes the automatic update of preview/teaser images on the overview page (in the first commit) and also hides/shows rooms on the overview page depending on successful loading of the preview image, assuming that a stream is 'live' when the preview image can be loaded.
The change was inspired by a suggestion from @saerdnaer in the
#voc-lounge
, where I missed the part about fixing this onmedia.ccc.de
at first and implemented it for the streaming website instead, which has a somewhat similar issue - and where implementing this is probably a bit easier. I'm not sure it's a good idea though to do this on the overview page, as it renders rooms where loading of the preview image fails 'inaccessible', so I don't mind if this PR gets discarded.